package cn.melonlib.graphql.model.support.filter;

import cn.melonlib.graphql.annos.GraphqlField;
import cn.melonlib.graphql.annos.GraphqlType;
import cn.melonlib.graphql.annos.GraphqlTypeDeclare;
import cn.melonlib.graphql.model.enums.GraphqlTypeMode;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.Getter;

import java.util.List;

@Data
@GraphqlType(comment = "字符串输入",namespaces = "*",declares = {@GraphqlTypeDeclare(mode = GraphqlTypeMode.INPUT)})
public class GraphqlStringFilter {

    @GraphqlField(comment = "像等 [=]")
    private String eq;

    @GraphqlField(comment = "不等于 [!=, <>] ")
    private String neq;

    @GraphqlField(comment = "小于 [<]")
    private String lt;

    @GraphqlField(comment = "大于 [>]")
    private String gt;

    @GraphqlField(comment = "小于等于 [<=]")
    private String lte;

    @GraphqlField(comment = "大于等于 [>=]")
    private String gte;

    @GraphqlField(comment = "包含 数据库查询[in]")
    private List<String> in;

    @GraphqlField(comment = "不包含 数据库查询[not in]")
    private List<String> nin;

    @GraphqlField(comment = "空判断 数据库查询[true 为 is null，false 为 is not null]")
    private boolean non;

    @GraphqlField(comment = "模糊判断 数据库查询[like 值前后加%] 内存检索模式[String.indexOf,正则表达模式] 搜索引擎方式")
    private String like;

}
